﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Data.SqlClient;
using Class_DAO;

namespace Project_QuangCaoABC
{
    public partial class frmReportDSNhanVien_HopDong : Form
    {
        public frmReportDSNhanVien_HopDong()
        {
            InitializeComponent();
        }

       

        private void frmReportDSNhanVien_HopDong_Load(object sender, EventArgs e)
        {
            string sql = "select * from HopDong";
            string sql1 = "select * from NhanVien";
            string stconet = DataProvider.GetBaoCao();
            SqlDataAdapter da = new SqlDataAdapter(sql, stconet);
            SqlDataAdapter da1 = new SqlDataAdapter(sql1, stconet);

            QuangCaoABCDataSet ds = new QuangCaoABCDataSet();

            da.Fill(ds, "HopDong");
            da1.Fill(ds, "NhanVien");
            rpDSNV_HopDong rphd_NV = new rpDSNV_HopDong();
            rphd_NV.SetDataSource(ds);
            ReportViewer_DSNV_HD.ReportSource = rphd_NV;

        }
    }
}
